#!usr/bin/python
# -*- coding: utf-8 -*-
#计算房屋

class Fangjia(object):
    def __init__(self,building_area,give_area,shared,price,avg_price,tax):
        self.building_area = building_area  #建筑面积
        self.give_area = give_area  #赠送面积
        self.shared = shared  #公摊比
        self.avg_price = avg_price #均价
        self.price = price #单价
        self.tax = tax #契税比
        self.Sum_area = self.building_area+self.give_area  #总面积=建筑面积+赠送

    #按折后单价*总面积
    def zongjia1(self):
        Sum_area = self.Sum_area
        total_prices = Sum_area*self.avg_price              #总房款
        Deed_tax = total_prices*self.tax/100            #契税
        sum_all  = total_prices+Deed_tax                #房屋总价
        usable_area1 = self.building_area*(1-shared/100)+self.give_area
        usable_area2 = Sum_area*(1-shared/100)
        print "房屋总面积为：%.2f, 总房款为: %.2f, 契税: %.2f, 总计： %.2f " % (Sum_area,total_prices,Deed_tax,sum_all)
        print "使用面积在 %.2f 到 %.2f 之间" % (usable_area2,usable_area1)

    def zongjia2(self):
        Sum_area = self.Sum_area
        total_prices = building_area*self.price              #总房款
        avg_price = total_prices/Sum_area
        print "房屋总价：%.2f, 均价为： %.2f 总面积：%.2f 单价：%.2f" % (total_prices,avg_price,Sum_area,self.price)

    
if __name__ == "__main__":
    building_area = float(raw_input("请输入建筑面积: "))
    give_area = float(raw_input("请输入赠送面积: "))
    shared = float(raw_input("请输入公摊比： "))
    
    price = int(raw_input("请输入房屋单价: "))
    avg_price = int(raw_input("请输入房屋均价: "))
    tax = float(raw_input("请输入契税："))
    s = Fangjia(building_area,give_area,shared,price,avg_price,tax)
    s.zongjia1()
    s.zongjia2()
else:
    pass
